home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 25 / CU Amiga Magazine's Super CD-ROM 25 (1998)(EMAP Images)(GB)(Track 1 of 2)[!][issue 1998-08].iso / CUCD / Programming / ixemul / sdk / man / cat5 / fstab.0 < prev    next >
Encoding:
Text File  |  1998-06-15  |  6.2 KB  |  124 lines

  1.  
  2. FSTAB(5)                   UNIX Programmer's Manual                   FSTAB(5)
  3.  
  4. NNAAMMEE
  5.      ffssttaabb - static information about the filesystems
  6.  
  7. SSYYNNOOPPSSIISS
  8.      ##iinncclluuddee <<ffssttaabb..hh>>
  9.  
  10. DDEESSCCRRIIPPTTIIOONN
  11.      The file ffssttaabb contains descriptive information about the various file
  12.      systems.  ffssttaabb is only read by programs, and not written; it is the duty
  13.      of the system administrator to properly create and maintain this file.
  14.      Each filesystem is described on a separate line; fields on each line are
  15.      separated by tabs or spaces.  The order of records in ffssttaabb is important
  16.      because fsck(8),  mount(8),  and umount(8) sequentially iterate through
  17.      ffssttaabb doing their thing.
  18.  
  19.      The first field, (_f_s___s_p_e_c), describes the block special device or remote
  20.      filesystem to be mounted.  For filesystems of type _f_f_s, the special file
  21.      name is the block special file name, and not the character special file
  22.      name.  If a program needs the character special file name, the program
  23.      must create it by appending a ``r'' after the last ``/'' in the special
  24.      file name.
  25.  
  26.      The second field, (_f_s___f_i_l_e), describes the mount point for the filesys-
  27.      tem.  For swap partitions, this field should be specified as ``none''.
  28.  
  29.      The third field, (_f_s___v_f_s_t_y_p_e), describes the type of the filesystem.  The
  30.      system currently supports eleven types of filesystems:
  31.  
  32.            _a_d_o_s_f_s  An AmigaOS filesystem
  33.  
  34.            _c_d_9_6_6_0  an ISO 9660 CD-ROM filesystem
  35.  
  36.            _f_d_e_s_c   an implementation of /dev/fd
  37.  
  38.            _f_f_s     a local UNIX filesystem
  39.  
  40.            _k_e_r_n_f_s  various and sundry kernel statistics
  41.  
  42.            _m_f_s     a local memory-based UNIX filesystem
  43.  
  44.            _m_s_d_o_s   a MSDOS ``FAT'' filesystem
  45.  
  46.            _n_f_s     a Sun Microsystems compatible ``Network File System''
  47.  
  48.            _p_r_o_c_f_s  a local filesystem of process information
  49.  
  50.            _s_w_a_p    a disk partition to be used for swapping
  51.  
  52.            _u_n_i_o_n   a translucent filesystem
  53.  
  54.      The fourth field, (_f_s___m_n_t_o_p_s), describes the mount options associated
  55.      with the filesystem.  It is formatted as a comma separated list of op-
  56.      tions.  It contains at least the type of mount (see _f_s___t_y_p_e below) plus
  57.      any additional options appropriate to the filesystem type.
  58.  
  59.      If the options ``userquota'' and/or ``groupquota'' are specified, the
  60.      filesystem is automatically processed by the quotacheck(8) command, and
  61.      user and/or group disk quotas are enabled with quotaon(8).  By default,
  62.      filesystem quotas are maintained in files named _q_u_o_t_a_._u_s_e_r and
  63.      _q_u_o_t_a_._g_r_o_u_p which are located at the root of the associated filesystem.
  64.      These defaults may be overridden by putting an equal sign and an alterna-
  65.      tive absolute pathname following the quota option.  Thus, if the user
  66.      quota file for _/_t_m_p is stored in _/_v_a_r_/_q_u_o_t_a_s_/_t_m_p_._u_s_e_r, this location can
  67.      be specified as:
  68.  
  69.            userquota=/var/quotas/tmp.user
  70.  
  71.      The type of the mount is extracted from the _f_s___m_n_t_o_p_s field and stored
  72.      separately in the _f_s___t_y_p_e field (it is not deleted from the _f_s___m_n_t_o_p_s
  73.      field).  If _f_s___t_y_p_e is ``rw'' or ``ro'' then the filesystem whose name is
  74.      given in the _f_s___f_i_l_e field is normally mounted read-write or read-only on
  75.      the specified special file.  If _f_s___t_y_p_e is ``sw'' then the special file
  76.      is made available as a piece of swap space by the swapon(8) command at
  77.      the end of the system reboot procedure.  The fields other than _f_s___s_p_e_c
  78.      and _f_s___t_y_p_e are unused.  If _f_s___t_y_p_e is specified as ``xx'' the entry is
  79.      ignored.  This is useful to show disk partitions which are currently un-
  80.      used.
  81.  
  82.      The fifth field, (_f_s___f_r_e_q), is used for these filesystems by the dump(8)
  83.      command to determine which filesystems need to be dumped.  If the fifth
  84.      field is not present, a value of zero is returned and dump will assume
  85.      that the filesystem does not need to be dumped.
  86.  
  87.      The sixth field, (_f_s___p_a_s_s_n_o), is used by the fsck(8) program to determine
  88.      the order in which filesystem checks are done at reboot time.  The root
  89.      filesystem should be specified with a _f_s___p_a_s_s_n_o of 1, and other filesys-
  90.      tems should have a _f_s___p_a_s_s_n_o of 2.  Filesystems within a drive will be
  91.      checked sequentially, but filesystems on different drives will be checked
  92.      at the same time to utilize parallelism available in the hardware.  If
  93.      the sixth field is not present or zero, a value of zero is returned and
  94.      fsck will assume that the filesystem does not need to be checked.
  95.  
  96.      #define FSTAB_RW        "rw"    /* read-write device */
  97.      #define FSTAB_RO        "ro"    /* read-only device */
  98.      #define FSTAB_SW        "sw"    /* swap device */
  99.      #define FSTAB_XX        "xx"    /* ignore totally */
  100.  
  101.      struct fstab {
  102.              char    *fs_spec;       /* block special device name */
  103.              char    *fs_file;       /* filesystem path prefix */
  104.              char    *fs_vfstype;    /* type of filesystem */
  105.              char    *fs_mntops;     /* comma separated mount options */
  106.              char    *fs_type;       /* rw, ro, sw, or xx */
  107.              int     fs_freq;        /* dump frequency, in days */
  108.              int     fs_passno;      /* pass number on parallel dump */
  109.      };
  110.  
  111.      The proper way to read records from _f_s_t_a_b is to use the routines
  112.      getfsent(3),  getfsspec(3),  getfstype(3),  and getfsfile(3).
  113.  
  114. FFIILLEESS
  115.      /etc/fstab  The file ffssttaabb resides in _/_e_t_c.
  116.  
  117. SSEEEE AALLSSOO
  118.      getfsent(3)
  119.  
  120. HHIISSTTOORRYY
  121.      The ffssttaabb file format appeared in 4.0BSD.
  122.  
  123. 4th Berkeley Distribution        June 5, 1993                                2
  124.